package org.wmq.skyserver;

import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.cache.annotation.EnableCaching;
import org.springframework.context.annotation.Bean;
import org.springframework.scheduling.annotation.EnableScheduling;
import org.springframework.transaction.annotation.EnableTransactionManagement;
import org.wmq.skycommon.WebSocket.WebSocketServer;
import org.wmq.skycommon.task.MyTask;
import org.wmq.skycommon.task.OrderTask;
import org.wmq.skyserver.task.OrderTask;

@SpringBootApplication
@EnableCaching
@EnableTransactionManagement
@EnableScheduling
public class SkyServerApplication {

    public static void main(String[] args) {
        SpringApplication.run(SkyServerApplication.class, args);
    }


    @Bean
    public MyTask myTask() {
        return new MyTask();
    }

    @Bean
    public org.wmq.skyserver.task.OrderTask orderTask() {
        return new org.wmq.skyserver.task.OrderTask();
    }

    @Bean
    public WebSocketServer webSocketServer() {
        return new WebSocketServer();
    }
}
